package com.example.demo8.dao;

import com.example.demo8.entity.Task;

import java.io.IOException;
import java.util.List;

public interface ITaskDao {
    public List<Task> getAll() throws IOException;

    public List<Task> getAllByName(String taskName) throws IOException;
    //根据ID修改数据
    void update(Task task) throws IOException;
    //根据id查询数据
    Task getById(Integer taskId) throws IOException;
    //根据id删除数据
    void delete(Integer taskId) throws IOException;

    //添加数据
    void add(Task task) throws IOException;
    //删除所有数据
    void deleteAll() throws IOException;
    //显示数据总数
    int getCount() throws IOException;
    //显示分页查询
    List<Task> getAllByPage(int start, int end) throws IOException;
}
